<?php
session_start();
require_once('path.php');
require_once( SOJ_ROOT.'/include/function/lib.php');

@$request = $_POST;

$PEAR_log = &Log::factory('file', 'soj.log', 'soj');  


try{

	$db = db_connect();
	$code_process = new code_process( $db , $request );
	$code_process->save();

	$code_file_name = $code_process->get_code_file_name() ;
	echo "<a href='do_code_judge.php?code_file_name=$code_file_name'>do judge now ?</a>" ;

}catch(Exception $e){
	
	exception_handle( $e );
}
